﻿<%@ page language="java" contentType="text/html; charset=UTF-8"  pageEncoding="UTF-8"%>  
<%@ include file="../common/taglib.jsp"%>  
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>CRM客户关系管理系统-登录</title>
    <link rel="stylesheet" href="${path}/statics/themes/default/style.css" />
    <%@ include file="../common/meta.jsp"%> 
    
    <script type="text/javascript" language="javascript">
    
    $(function(){
    	(function(){
    		var curr = 0;
    		$("#jsNav .trigger").each(function(i){
    			$(this).click(function(){
    				curr = i;
    				$("#ad img").eq(i).fadeIn("slow").siblings("img").hide();
    				$(this).siblings(".trigger").removeClass("imgSelected").end().addClass("imgSelected");
    				return false;
    			});
    		});
    		
    		var pg = function(flag){
    			//flag:true表示前翻， false表示后翻
    			if (flag) {
    				if (curr == 0) {
    					todo = 2;
    				} else {
    					todo = (curr - 1) % 3;
    				}
    			} else {
    				todo = (curr + 1) % 3;
    			}
    			$("#jsNav .trigger").eq(todo).click();
    		};
    		
    		//前翻
    		$("#prev").click(function(){
    			pg(true);
    			return false;
    		});
    		
    		//后翻
    		$("#next").click(function(){
    			pg(false);
    			return false;
    		});
    		
    		//自动翻
    		var timer = setInterval(function(){
    			todo = (curr + 1) % 3;
    			$("#jsNav .trigger").eq(todo).click();
    		},4000);
    		
    		//鼠标悬停在触发器上时停止自动翻
    		$("#jsNav a").hover(function(){
    				clearInterval(timer);
    			},
    			function(){
    				timer = setInterval(function(){
    					todo = (curr + 1) % 3;
    					$("#jsNav .trigger").eq(todo).click();
    				},1500);			
    			}
    		);
    	})();
    });
	
	$(document).ready(	function() { 
		if("${msg}"!=""){
			//var dialog = art.dialog({id: 'N3690',title: "aaaaaaaa",content:"ddd"});
			art.dialog({
			    content: '${msg}',
			    ok: function () {
			    },
			    cancelVal: '关闭',
			    cancel: true //为true等价于function(){}
			});
		}
	})
	
	function login(){
		var form=document.getElementById("loginform");
		form.submit();
	}
	
	$(function(){		
		$("#codeImg").click(function(){
			var currentTime=new Date().getTime();
			$("#codeImg").attr("src","/?acctime="+currentTime);
		});
	});
	
	function takePress(){
		  if(event.keyCode == 13){
			  login();
		  }
		}
</script>

</head>
<body id="login" scroll="no" onkeypress="takePress()">
    <div class="container">
    
    <div style="margin-right: 0px;float: right;margin-left: 0px;">
        <a href="${path}"  style=""></a>
       </div>
        <div class="header">
            <h1>
               CRM客户关系管理系统</h1>
            <!--<div class="link-tools">
                <a href="###">
                    <img src="${path}/statics/images/login-yinxiao.gif" /></a></div>
                    
                    --><div class="bshare-custom" style="text-align: right;">
			<a class="bshare-more  more-style-addthis" title="更多平台">
			<img src="${path}/statics/images/login-yinxiao.gif" />
			</a></div>
			<script type="text/javascript" charset="utf-8" src="http://static.bshare.cn/b/buttonLite.js#style=-1&amp;uuid=&amp;pophcol=2&amp;lang=zh"></script>
			<script type="text/javascript" charset="utf-8" src="http://static.bshare.cn/b/bshareC0.js"></script>
        </div>
        <div class="content">
            <div class="login-form">

				<div class="login-ads">
					<div id="content">
						<div class="ad" id=ad>
							<img src="${path}/statics/images/login_001.jpg" /> 
							<img
								style="DISPLAY: none" src="${path}/statics/images/login_002.jpg" />
							<img style="DISPLAY: none"
								src="${path}/statics/images/login_003.jpg" /> 
							<DIV id="jsNav" class="jsNav">
								<A id="prev" class="prevBtn" href="javascript:void(0)"></A>
								<A class="trigger imgSelected" href="javascript:void(0)">1</A>
								<A class="trigger" href="javascript:void(0)">2</A>
								<A class=trigger href="javascript:void(0)">3</A>
								<A id="next" class="nextBtn" href="javascript:void(0)"></A>
							</DIV>
						</div>
					</div>
				</div>

				<div class="login-table">
                <form method="post" name="loginform" id="loginform" action="${path }/login/index">
                    <table cellpadding="0" cellspacing="0">
                        <tr>
                            <th>
                                用户名(U)：
                            </th>
                            <td> 
							<input id="username" name="username" type="text" tabindex=1 />
                            </td>
                        </tr>
                        <tr>
                            <th>
                                密&nbsp;&nbsp;&nbsp;&nbsp;码(P)：
                            </th>
                            <td>
                                <input id="pwd" name="pwd" type="password" tabindex=2 />
                            </td>
                        </tr>
                       
                        <tfoot>
                            <tr>
                                <th>
                                </th>
                                <td>
                                    <a href="javascript:" class="login-linkbtn" onclick="login()"><span>登 录</span></a>  
                                    <%-- <a href="${path}/login/forget/index" style=" margin-left:15px;">忘记密码？</a> --%>
                                </td>
                            </tr>
                        </tfoot>
                    </table>
                    </form>
                </div>
            </div>
        </div>
    </div>
    <div class="footer">
        <p>
            Copyright © 2012 - 2013 90Team. All Rights Reserved<br>
						版权所有 翻版必究
        </p>
    </div>
    <div class="extraDiv1">
        <span></span>
    </div>
    <div class="extraDiv2">
        <span></span>
    </div>
    <div class="extraDiv3">
        <span></span>
    </div>
</body>
</html>
 